package com.telecom.cms.service;

import java.util.List;
import java.util.HashMap;
import com.telecom.cms.dao.CampEmpAppdDAO;
import com.telecom.cms.dao.SysGetIdDAO;
import com.telecom.cms.dto.CampEmpAppd;
import com.telecom.cms.dao.CampCampDAO;
import com.telecom.cms.dto.CampCamp;

public class CampEmpAppdMgr {
   
	public void save(CampEmpAppd campcamp){
		(new CampEmpAppdDAO()).insert(campcamp);
	}
	
	public void  delete(CampEmpAppd campcamp){
		(new CampEmpAppdDAO()).delete(campcamp);
	}
	
	public void  delete(String campid,String campseqid){
		(new CampEmpAppdDAO()).delete(campid,campseqid);
	}
	
	public List findall(){
		List result=(new CampEmpAppdDAO()).findAll();
		return result;
	}
	
	public List findall(String campid,String campseqid){
		List result=(new CampEmpAppdDAO()).findAll(campid,campseqid);
		return result;
	}
	
	public CampEmpAppd findbyid(String campid,String campseqid,String userid){
		CampEmpAppd result=(new CampEmpAppdDAO()).findById(campid,campseqid,userid);
		return result;
	}
	
	public List findallbyuser(String userid){
		List result=(new CampEmpAppdDAO()).findAllByUser(userid);
		return result;
	}
	
	public String getscriptfile(String campid)
	{
		return (new CampCampDAO()).findById(campid).getCampScript();
	}
	
	public List findAccsNbrs(String latnid,String custid)
	{
		return (new SysGetIdDAO()).findAccsNbrs(latnid,custid);
	}
	
	public HashMap findAccsNbrsmap(String latnid,List adllist,int from)
	{
		return (new SysGetIdDAO()).findAccsNbrsmap(latnid,adllist,from);
	}
}
